package com.crm.entity;

import java.io.Serializable;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;

import org.hibernate.annotations.GenericGenerator;

@Entity
@Table(name="part_sources")
public class PartSources implements Serializable {
	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;

	@Id
	@GeneratedValue(generator="increment")
	@GenericGenerator(name="increment", strategy = "increment")
	@Column(name="id")
	private int id;

	private int sourceid;

	private int enqid;

	
	@ManyToOne
	@JoinColumn(name="PARTID")
	private Parts partid;
	
	@Column(name="mail_sent")
	private boolean mailSent;
	
	@Column(name="is_src_completed")
	private boolean isSourceCompleted;
	
	
	@ManyToOne
	@JoinColumn(name="BUSINESS_ID")
	private Business businessId;
	

	public Business getBusinessId() {
		return businessId;
	}

	public void setBusinessId(Business businessId) {
		this.businessId = businessId;
	}

	public boolean isMailSent() {
		return mailSent;
	}

	public void setMailSent(boolean mailSent) {
		this.mailSent = mailSent;
	}


	public boolean isSourceCompleted() {
		return isSourceCompleted;
	}

	public void setSourceCompleted(boolean isSourceCompleted) {
		this.isSourceCompleted = isSourceCompleted;
	}

	

	public PartSources() {
		super();
	}

	public int getId() {
		return this.id;
	}

	public void setId(int id) {
		this.id = id;
	}

	public int getSourceid() {
		return this.sourceid;
	}

	public void setSourceid(int sourceid) {
		this.sourceid = sourceid;
	}

	public int getEnqid() {
		return this.enqid;
	}

	public void setEnqid(int enqid) {
		this.enqid = enqid;
	}

	public Parts getPartid() {
		return partid;
	}

	public void setPartid(Parts partid) {
		this.partid = partid;
	}

	

}
